package com.apple1.commonutil.common;

/**
 * @author chencheng
 * @date 2019-01-29
 */
public class SmsResponse {
    //  {"reason":"操作成功","result":{"sid":"190129144545103014100020","fee":1,"count":1},"error_code":0}
    private String reason;

    private Info result;

    private Integer error_code;


    public static SmsResponse error() {
        SmsResponse smsResult = new SmsResponse();
        smsResult.error_code = -500;

        smsResult.reason = "网络错误";
        return  smsResult;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public Info getResult() {
        return result;
    }

    public void setResult(Info result) {
        this.result = result;
    }

    public Integer getError_code() {
        return error_code;
    }

    public void setError_code(Integer error_code) {
        this.error_code = error_code;
    }

    @Override
    public String toString() {
        return "SmsResponse{" +
                "reason='" + reason + '\'' +
                ", result=" + result +
                ", error_code=" + error_code +
                '}';
    }
}

    class Info{
        String sid; /*短信ID*/
        Integer count; /*发送数量*/
        Integer fee;  /*扣除条数*/

        public String getSid() {
            return sid;
        }

        public void setSid(String sid) {
            this.sid = sid;
        }

        public Integer getCount() {
            return count;
        }

        public void setCount(Integer count) {
            this.count = count;
        }

        public Integer getFee() {
            return fee;
        }

        public void setFee(Integer fee) {
            this.fee = fee;
        }
    }

